'use strict';

// 接收到数据调用
module.exports = app => {
  class Controller extends app.Controller {
    async index() {
      const nsp = this.app.io.of('/date');
      nsp.adapter.remoteDisconnect(this.ctx.socket.id, true, () => {
        console.log('关闭链接');
      });
    }
  }
  return Controller;
};

